input_str = input("请输入一行字符：")

str_list = [0, 0, 0, 0]
for i in input_str:
    if i.isalpha():
        str_list[0] += 1
    elif i.isspace():
        str_list[1] += 1
    elif i.isdigit():
        str_list[2] += 1
    else:
        str_list[3] += 1

str_tuple = tuple(str_list)
print("英文字母个数为：%d\n"
      "空格个数为%d\n"
      "数字个数为%d\n"
      "其他字符个数为%d" % str_tuple)
